<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<meta name="viewport" content="width=device-width,initial-scale=1,shrink-to-fit=no">
		<title>找回密码第一步-<?php echo $cfg_webname;?></title>
		<link rel="stylesheet" href="/static/web/css/font-awesome.min.css">
		<link rel="stylesheet" href="/static/web/css/bootstrap.min.css">
		<link rel="stylesheet" href="/static/web/css/style.css">
	</head>
	<body>
		<?php obtaintheme('top.htm');?>
		<main class="container py-3">
			<h2>找回密码第一步</h2>
			<p><a href="index_do.php?fmdo=user&dopost=regnew">还没注册？</a></p>
			<form name="form1" method="POST" action="<?php echo $cfg_memberurl;?>/resetpassword.php">
				<input type="hidden" name="dopost" value="getpwd">
				<input type="hidden" name="gourl" value="<?php if (!empty($gourl)) echo $gourl;?>">
				<div class="form-group">
					<label for="iptUserid">账号</label>
					<input type="text" name="userid" id="iptUserid" class="form-control" placeholder="请输入账号" required>
				</div>
				<div class="form-group">
					<label for="selType">找回方式</label>
					<div class="input-group">
						<select name="type" id="selType" class="form-control" change="">
							<option value="1" selected>通过邮件取回</option>
							<option value="2">通过安全问题取回</option>
						</select>
					</div>
				</div>
				<div class="form-group" id="mail-box">
					<label for="iptMail">邮箱</label>
					<input type="text" name="mail" id="iptMail" class="form-control" placeholder="请输入邮箱">
				</div>
				<div class="form-group">
					<label for="iptValidate">验证码</label>
					<div class="input-group">
						<input type="text" name="vdcode" id="iptValidate" class="form-control text-uppercase" placeholder="请输入验证码" required>
						<div class="input-group-append"><img src="<?php echo $cfg_phpurl;?>/vdimgck.php" id="validateimg" onclick="this.src='<?php echo $cfg_phpurl;?>/vdimgck.php?'+new Date().getTime()+Math.round(Math.random() * 10000)" title="验证码"></div>
					</div>
				</div>
				<div><button type="submit" class="btn btn-success btn-block">下一步</button></div>
			</form>
		</main>
		<?php obtaintheme('foot.htm');?>
		<script>
			$(document).ready(function() {
				$("#selType").on("change", function() {
					if (this.value == 2) {
						$("#mail-box").hide();
					} else {
						$("#mail-box").show();
					}
				});
			});
		</script>
	</body>
</html>